package com.handytoo.cow_core.network.Config;

import lombok.Getter;
import lombok.Setter;
import org.springframework.boot.context.properties.ConfigurationProperties;

/**
 * 自定义网络模块代码
 */
@Setter
@Getter
@ConfigurationProperties(prefix = "handytoo.tcp")
public class TcpConfig {
    private int port = 54887;
    private int workThreads = 16;
    private int defaultLowWaterMark = 524288;
    private int defaultHighWaterMark = 1048576;
    private int heartbeat = 0;
    private int maxConnection = Integer.MAX_VALUE;
    private boolean encrypt = false;
    private String secretKey = "whoami";
    private boolean receiveActive = false;
    private int receiveThreshold = 65535;
    private int receiveSecond = 5;
    private int receiveCount = 3;
    private boolean trafficShaping = false;
    private int writeLimit = 0;
    private int readLimit = 0;
    private int checkInterval = 1000;
    private int maxTime = 15000;

    public TcpConfig() {
    }

}
